<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
<meta name="generator" content="Doxygen 1.9.4"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Flow-IPC: ipc::shm::stl::Stateless_allocator&lt; T, Arena &gt; Class Template Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr id="projectrow">
  <td id="projectalign">
   <div id="projectname">Flow-IPC<span id="projectnumber">&#160;2.0.0</span>
   </div>
   <div id="projectbrief">Flow-IPC project: Full implementation reference.</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.4 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
var searchBox = new SearchBox("searchBox", "search",'Search','.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */
</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="namespaceipc.html">ipc</a></li><li class="navelem"><a class="el" href="namespaceipc_1_1shm.html">shm</a></li><li class="navelem"><a class="el" href="namespaceipc_1_1shm_1_1stl.html">stl</a></li><li class="navelem"><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">Stateless_allocator</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#pub-types">Public Types</a> &#124;
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#related">Related Functions</a> &#124;
<a href="classipc_1_1shm_1_1stl_1_1Stateless__allocator-members.html">List of all members</a>  </div>
  <div class="headertitle"><div class="title">ipc::shm::stl::Stateless_allocator&lt; T, Arena &gt; Class Template Reference</div></div>
</div><!--header-->
<div class="contents">

<p>Stateless allocator usable with STL-compliant containers to store (or merely read) them directly in SHM in a given SHM-aware <code>Arena</code>.  
 <a href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="stateless__allocator_8hpp_source.html">stateless_allocator.hpp</a>&gt;</code></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pub-types" name="pub-types"></a>
Public Types</h2></td></tr>
<tr class="memitem:a8bf26ee2ae30dfbe4d64fbcad3ac8368"><td class="memItemLeft" align="right" valign="top">using&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#a8bf26ee2ae30dfbe4d64fbcad3ac8368">Value</a> = T</td></tr>
<tr class="memdesc:a8bf26ee2ae30dfbe4d64fbcad3ac8368"><td class="mdescLeft">&#160;</td><td class="mdescRight">Short-hand for <code>T</code>.  <a href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#a8bf26ee2ae30dfbe4d64fbcad3ac8368">More...</a><br /></td></tr>
<tr class="separator:a8bf26ee2ae30dfbe4d64fbcad3ac8368"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab8733c1237be93ee28664e4b983d535c"><td class="memItemLeft" align="right" valign="top">using&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8733c1237be93ee28664e4b983d535c">Arena_obj</a> = Arena</td></tr>
<tr class="memdesc:ab8733c1237be93ee28664e4b983d535c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Short-hand for the <code>Arena</code> type this uses for allocation/deallocation/pointer semantics.  <a href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8733c1237be93ee28664e4b983d535c">More...</a><br /></td></tr>
<tr class="separator:ab8733c1237be93ee28664e4b983d535c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab2ed725ef3e8128a35f6ef429fb1fdcb"><td class="memItemLeft" align="right" valign="top">using&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab2ed725ef3e8128a35f6ef429fb1fdcb">Pointer</a> = typename Arena_obj::template <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab2ed725ef3e8128a35f6ef429fb1fdcb">Pointer</a>&lt; <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#a8bf26ee2ae30dfbe4d64fbcad3ac8368">Value</a> &gt;</td></tr>
<tr class="memdesc:ab2ed725ef3e8128a35f6ef429fb1fdcb"><td class="mdescLeft">&#160;</td><td class="mdescRight">The required pointer-like type. See also <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ae1fc58777e7e727af17fbf0cdaf850bf" title="Alias to Pointer for compatibility with STL-compliant machinery (traits, etc.).">pointer</a>.  <a href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab2ed725ef3e8128a35f6ef429fb1fdcb">More...</a><br /></td></tr>
<tr class="separator:ab2ed725ef3e8128a35f6ef429fb1fdcb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae1fc58777e7e727af17fbf0cdaf850bf"><td class="memItemLeft" align="right" valign="top">using&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ae1fc58777e7e727af17fbf0cdaf850bf">pointer</a> = <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab2ed725ef3e8128a35f6ef429fb1fdcb">Pointer</a></td></tr>
<tr class="memdesc:ae1fc58777e7e727af17fbf0cdaf850bf"><td class="mdescLeft">&#160;</td><td class="mdescRight">Alias to <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab2ed725ef3e8128a35f6ef429fb1fdcb" title="The required pointer-like type. See also pointer.">Pointer</a> for compatibility with STL-compliant machinery (traits, etc.).  <a href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ae1fc58777e7e727af17fbf0cdaf850bf">More...</a><br /></td></tr>
<tr class="separator:ae1fc58777e7e727af17fbf0cdaf850bf"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:afa85349670ddd8da1eb0386a2556f753"><td class="memItemLeft" align="right" valign="top">using&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#afa85349670ddd8da1eb0386a2556f753">value_type</a> = <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#a8bf26ee2ae30dfbe4d64fbcad3ac8368">Value</a></td></tr>
<tr class="memdesc:afa85349670ddd8da1eb0386a2556f753"><td class="mdescLeft">&#160;</td><td class="mdescRight">Alias to <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#a8bf26ee2ae30dfbe4d64fbcad3ac8368" title="Short-hand for T.">Value</a> for compatibility with STL-compliant machinery (traits, etc.).  <a href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#afa85349670ddd8da1eb0386a2556f753">More...</a><br /></td></tr>
<tr class="separator:afa85349670ddd8da1eb0386a2556f753"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pub-methods" name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:a5ee014d337762aef9c2fbac0585cdfd1"><td class="memItemLeft" align="right" valign="top"><a id="a5ee014d337762aef9c2fbac0585cdfd1" name="a5ee014d337762aef9c2fbac0585cdfd1"></a>
&#160;</td><td class="memItemRight" valign="bottom"><b>Stateless_allocator</b> ()</td></tr>
<tr class="memdesc:a5ee014d337762aef9c2fbac0585cdfd1"><td class="mdescLeft">&#160;</td><td class="mdescRight"><a class="el" href="classAllocator.html">Allocator</a> concept requirement for default-ctor: no-op since it's a stateless allocator. <br /></td></tr>
<tr class="separator:a5ee014d337762aef9c2fbac0585cdfd1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a07b30ebd16bf82a87186c7baffc9bf85"><td class="memTemplParams" colspan="2">template&lt;typename U &gt; </td></tr>
<tr class="memitem:a07b30ebd16bf82a87186c7baffc9bf85"><td class="memTemplItemLeft" align="right" valign="top">&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#a07b30ebd16bf82a87186c7baffc9bf85">Stateless_allocator</a> (const <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">Stateless_allocator</a>&lt; U, Arena &gt; &amp;src_ignored)</td></tr>
<tr class="memdesc:a07b30ebd16bf82a87186c7baffc9bf85"><td class="mdescLeft">&#160;</td><td class="mdescRight"><a class="el" href="classAllocator.html">Allocator</a> concept requirement for copy-ctor from allocator-to-another-type: no-op since it's a stateless allocator.  <a href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#a07b30ebd16bf82a87186c7baffc9bf85">More...</a><br /></td></tr>
<tr class="separator:a07b30ebd16bf82a87186c7baffc9bf85"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aff55fe717e40aca873192819bf1afc15"><td class="memTemplParams" colspan="2">template&lt;typename U &gt; </td></tr>
<tr class="memitem:aff55fe717e40aca873192819bf1afc15"><td class="memTemplItemLeft" align="right" valign="top">&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#aff55fe717e40aca873192819bf1afc15">Stateless_allocator</a> (<a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">Stateless_allocator</a>&lt; U, Arena &gt; &amp;&amp;src_ignored)</td></tr>
<tr class="memdesc:aff55fe717e40aca873192819bf1afc15"><td class="mdescLeft">&#160;</td><td class="mdescRight"><a class="el" href="classAllocator.html">Allocator</a> concept requirement for move-ctor from allocator-to-another-type: no-op since it's a stateless allocator.  <a href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#aff55fe717e40aca873192819bf1afc15">More...</a><br /></td></tr>
<tr class="separator:aff55fe717e40aca873192819bf1afc15"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab8609f6d096e59799d249403905a0953"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab2ed725ef3e8128a35f6ef429fb1fdcb">Pointer</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8609f6d096e59799d249403905a0953">allocate</a> (size_t n) const</td></tr>
<tr class="memdesc:ab8609f6d096e59799d249403905a0953"><td class="mdescLeft">&#160;</td><td class="mdescRight">Allocates an uninitialized buffer of given size, or throws exception if <code>Arena_obj::allocate()</code> does; satisfies formal requirements of STL-compliant <code><a class="el" href="classAllocator.html">Allocator</a></code> concept.  <a href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8609f6d096e59799d249403905a0953">More...</a><br /></td></tr>
<tr class="separator:ab8609f6d096e59799d249403905a0953"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac6531b5bdb3b299e0780fc5b892bd70c"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ac6531b5bdb3b299e0780fc5b892bd70c">deallocate</a> (<a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab2ed725ef3e8128a35f6ef429fb1fdcb">Pointer</a> p, size_t n_ignored=0) const noexcept</td></tr>
<tr class="memdesc:ac6531b5bdb3b299e0780fc5b892bd70c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Deallocates buffer in SHM previously allocated via <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8609f6d096e59799d249403905a0953" title="Allocates an uninitialized buffer of given size, or throws exception if Arena_obj::allocate() does; s...">allocate()</a> in this or other (if <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8733c1237be93ee28664e4b983d535c" title="Short-hand for the Arena type this uses for allocation/deallocation/pointer semantics.">Arena_obj</a> supports this) process, as long as <code>p</code> refers to the beginning of the buffer returned by that <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8609f6d096e59799d249403905a0953" title="Allocates an uninitialized buffer of given size, or throws exception if Arena_obj::allocate() does; s...">allocate()</a>; satisfies formal requirement of STL-compliant <code><a class="el" href="classAllocator.html">Allocator</a></code> concept.  <a href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ac6531b5bdb3b299e0780fc5b892bd70c">More...</a><br /></td></tr>
<tr class="separator:ac6531b5bdb3b299e0780fc5b892bd70c"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="related" name="related"></a>
Related Functions</h2></td></tr>
<tr><td class="ititle" colspan="2"><p >(Note that these are not member functions.) </p>
</td></tr>
<tr class="memitem:a96ccf3e4cf39d59d0a80e9026507b206"><td class="memTemplParams" colspan="2">template&lt;typename Arena , typename T1 , typename T2 &gt; </td></tr>
<tr class="memitem:a96ccf3e4cf39d59d0a80e9026507b206"><td class="memTemplItemLeft" align="right" valign="top">bool&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#a96ccf3e4cf39d59d0a80e9026507b206">operator==</a> (const <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">Stateless_allocator</a>&lt; T1, Arena &gt; &amp;val1, const <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">Stateless_allocator</a>&lt; T2, Arena &gt; &amp;val2)</td></tr>
<tr class="memdesc:a96ccf3e4cf39d59d0a80e9026507b206"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns <code>true</code> for any 2 <code><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html" title="Stateless allocator usable with STL-compliant containers to store (or merely read) them directly in S...">Stateless_allocator</a></code>s managing the same <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8733c1237be93ee28664e4b983d535c" title="Short-hand for the Arena type this uses for allocation/deallocation/pointer semantics.">Stateless_allocator::Arena_obj</a>.  <a href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#a96ccf3e4cf39d59d0a80e9026507b206">More...</a><br /></td></tr>
<tr class="separator:a96ccf3e4cf39d59d0a80e9026507b206"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab1b059d00a9cbdc54a917e051c1aecdf"><td class="memTemplParams" colspan="2">template&lt;typename Arena , typename T1 , typename T2 &gt; </td></tr>
<tr class="memitem:ab1b059d00a9cbdc54a917e051c1aecdf"><td class="memTemplItemLeft" align="right" valign="top">bool&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab1b059d00a9cbdc54a917e051c1aecdf">operator!=</a> (const <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">Stateless_allocator</a>&lt; T1, Arena &gt; &amp;val1, const <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">Stateless_allocator</a>&lt; T2, Arena &gt; &amp;val2)</td></tr>
<tr class="memdesc:ab1b059d00a9cbdc54a917e051c1aecdf"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns <code>false</code> for any 2 <code><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html" title="Stateless allocator usable with STL-compliant containers to store (or merely read) them directly in S...">Stateless_allocator</a></code>s managing the same <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8733c1237be93ee28664e4b983d535c" title="Short-hand for the Arena type this uses for allocation/deallocation/pointer semantics.">Stateless_allocator::Arena_obj</a>.  <a href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab1b059d00a9cbdc54a917e051c1aecdf">More...</a><br /></td></tr>
<tr class="separator:ab1b059d00a9cbdc54a917e051c1aecdf"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><div class="compoundTemplParams">template&lt;typename T, typename Arena&gt;<br />
class ipc::shm::stl::Stateless_allocator&lt; T, Arena &gt;</div><p >Stateless allocator usable with STL-compliant containers to store (or merely read) them directly in SHM in a given SHM-aware <code>Arena</code>. </p>
<p >Please read background in <a class="el" href="namespaceipc_1_1shm_1_1stl.html" title="ipc::shm sub-module providing integration between STL-compliant components (including containers) and...">shm::stl</a> namespace doc header (shm_stl_fwd.hpp).</p>
<h3>How to use</h3>
<p >Suppose <code>T</code> is a container type with <code><a class="el" href="classAllocator.html">Allocator</a></code> template param given as <code><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html" title="Stateless allocator usable with STL-compliant containers to store (or merely read) them directly in S...">Stateless_allocator</a>&lt;E&gt;</code>, as well as any nested element types that are also containers also specifying <code><a class="el" href="classAllocator.html">Allocator</a></code> as <code><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html" title="Stateless allocator usable with STL-compliant containers to store (or merely read) them directly in S...">Stateless_allocator</a>&lt;...&gt;</code>. Suppose you want to work with a <code>T* t</code>, such that <code>t</code> points to <code>sizeof(T)</code> bytes in SHM inside some <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8733c1237be93ee28664e4b983d535c" title="Short-hand for the Arena type this uses for allocation/deallocation/pointer semantics.">Arena_obj</a> <code>A</code>. In order to perform any work on the <code>*t</code> &ndash; including construction, destruction, and any other operations that require internal alloc/dealloc/ptr-deref also inside <code>A</code> &ndash; activate <code>&amp;A</code> in the relevant thread using an <a class="el" href="classipc_1_1shm_1_1stl_1_1Arena__activator.html" title="RAII-style class operating a stack-like notion of a the given thread&#39;s currently active SHM-aware Are...">Arena_activator</a>. For example:</p>
<div class="fragment"><div class="line"><span class="keyword">using </span>Shm_classic_arena = <a class="code hl_class" href="classipc_1_1shm_1_1classic_1_1Pool__arena.html">classic::Pool_arena</a>;</div>
<div class="line"><span class="keyword">template</span>&lt;<span class="keyword">typename</span> T&gt;</div>
<div class="line"><span class="keyword">using </span>Shm_classic_allocator = <a class="code hl_class" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">Stateless_allocator&lt;T, Shm_classic_arena&gt;</a>;</div>
<div class="line"><span class="keyword">using </span>Shm_classic_arena_activator = <a class="code hl_class" href="classipc_1_1shm_1_1stl_1_1Arena__activator.html">Arena_activator&lt;Shm_classic_arena&gt;</a>;</div>
<div class="line"> </div>
<div class="line"><span class="keyword">struct </span>Widget { m_float m_a; m_int m_b; }</div>
<div class="line"><span class="keyword">using </span>Widget_list = list&lt;Widget, Shm_classic_allocator&lt;Widget&gt;&gt;;</div>
<div class="line"><span class="keyword">using </span>Widget_list_vec = vector&lt;Widget_list, Shm_classic_allocator&lt;Widget_list&gt;&gt;;</div>
<div class="line"> </div>
<div class="line">Shm_classic_arena a(...); <span class="comment">// Let `a` be a SHM-classic arena storing *x among other things.</span></div>
<div class="line"> </div>
<div class="line">Widget_list_vec* x = <span class="comment">// ...obtain pointer x to SHM-stored space for the Widget_list_vec in question.</span></div>
<div class="line">{</div>
<div class="line">  Shm_classic_arena_activator arena_ctx(&amp;a);</div>
<div class="line">  <span class="comment">// call x-&gt; ctors, dtor, methods, operators....</span></div>
<div class="line">} <span class="comment">// Return the active arena to previous value.</span></div>
<div class="ttc" id="aclassipc_1_1shm_1_1classic_1_1Pool__arena_html"><div class="ttname"><a href="classipc_1_1shm_1_1classic_1_1Pool__arena.html">ipc::shm::classic::Pool_arena</a></div><div class="ttdoc">A SHM-classic interface around a single SHM pool with allocation-algorithm services by boost....</div><div class="ttdef"><b>Definition:</b> <a href="pool__arena_8hpp_source.html#l00150">pool_arena.hpp:153</a></div></div>
<div class="ttc" id="aclassipc_1_1shm_1_1stl_1_1Arena__activator_html"><div class="ttname"><a href="classipc_1_1shm_1_1stl_1_1Arena__activator.html">ipc::shm::stl::Arena_activator</a></div><div class="ttdoc">RAII-style class operating a stack-like notion of a the given thread's currently active SHM-aware Are...</div><div class="ttdef"><b>Definition:</b> <a href="arena__activator_8hpp_source.html#l00040">arena_activator.hpp:41</a></div></div>
<div class="ttc" id="aclassipc_1_1shm_1_1stl_1_1Stateless__allocator_html"><div class="ttname"><a href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">ipc::shm::stl::Stateless_allocator</a></div><div class="ttdoc">Stateless allocator usable with STL-compliant containers to store (or merely read) them directly in S...</div><div class="ttdef"><b>Definition:</b> <a href="stateless__allocator_8hpp_source.html#l00118">stateless_allocator.hpp:119</a></div></div>
</div><!-- fragment --><p >Note you may nest <a class="el" href="classipc_1_1shm_1_1stl_1_1Arena__activator.html" title="RAII-style class operating a stack-like notion of a the given thread&#39;s currently active SHM-aware Are...">Arena_activator</a> contexts in stack-like fashion. Note, also, that <code><a class="el" href="classipc_1_1shm_1_1stl_1_1Arena__activator.html" title="RAII-style class operating a stack-like notion of a the given thread&#39;s currently active SHM-aware Are...">Arena_activator</a>&lt;A1&gt;</code> operates completely independently from <code><a class="el" href="classipc_1_1shm_1_1stl_1_1Arena__activator.html" title="RAII-style class operating a stack-like notion of a the given thread&#39;s currently active SHM-aware Are...">Arena_activator</a>&lt;A2&gt;</code>, even in the same thread, if <code>A1</code> is not same-as <code>A2</code>. So any "clash" would only occur (1) in a given thread, not across threads; (2) for a given SHM provider type, not across 2+ such types.</p>
<p >The allocator is <em>stateless</em>. It takes no space within any container that uses it; and it is always default-cted by the container code itself &ndash; never by the user. That is the reason <a class="el" href="classipc_1_1shm_1_1stl_1_1Arena__activator.html" title="RAII-style class operating a stack-like notion of a the given thread&#39;s currently active SHM-aware Are...">Arena_activator</a> is necessary (when allocating/deallocating).</p>
<h3><code>Arena</code> type requirements (for full capabilities)</h3>
<p >For write+allocate+deallocate capabilities of <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html" title="Stateless allocator usable with STL-compliant containers to store (or merely read) them directly in S...">Stateless_allocator</a>: an <code>Arena</code> must have the following members:</p><ul>
<li><code>void* allocate(size_t n);</code>: Allocate uninitialized buffer of <code>n</code> bytes in this SHM arena; return locally-dereferenceable pointer to that buffer. Throw exception if ran out of resources. (Some providers try hard to avoid this.)</li>
<li><code>void deallocate(void* p)</code>: Undo <code><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8609f6d096e59799d249403905a0953" title="Allocates an uninitialized buffer of given size, or throws exception if Arena_obj::allocate() does; s...">allocate()</a></code> that returned <code>p</code>; or the equivalent operation if the SHM provider allows process 2 to deallocate something that was allocated by process 1 (and <code>p</code> indeed was <code><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8609f6d096e59799d249403905a0953" title="Allocates an uninitialized buffer of given size, or throws exception if Arena_obj::allocate() does; s...">allocate()</a></code>ed in a different process but transmitted to the current process; and was properly made locally-dereferenceable before passing it to this method).</li>
<li><code>template&lt;typename T&gt; class Pointer</code>: <code>Pointer&lt;T&gt;</code> must, informally speaking, mimic <code>T*</code>; formally being a <em>fancy pointer</em> in the STL sense. The locally-dereferenceable <code>T*</code> it yields must point to the same underlying area in SHM regardless of in which <code>Arena</code>-aware process the deref API is invoked.<ul>
<li>The <code>class</code> keyword is for exposition only; it can also be <code>using</code>, <code>typedef</code>, or anything else, provided it mimics <code>T*</code> as described.</li>
<li>For example, if <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8733c1237be93ee28664e4b983d535c" title="Short-hand for the Arena type this uses for allocation/deallocation/pointer semantics.">Arena_obj</a> is <a class="el" href="classipc_1_1shm_1_1classic_1_1Pool__arena.html" title="A SHM-classic interface around a single SHM pool with allocation-algorithm services by boost....">classic::Pool_arena</a>, then <a class="el" href="classipc_1_1shm_1_1classic_1_1Pool__arena.html#a07fec7ff0ba494dca0f0a010270cc35f" title="SHM-storable fancy-pointer.">classic::Pool_arena::Pointer</a> might be <code>bipc::offset_ptr</code>, which internally stores merely an offset within the same SHM-pool versus its own <code>this</code>; this works great as long indeed the <code>Pointer</code> <em>itself</em> is located inside the SHM-pool as the thing to which it points.</li>
</ul>
</li>
</ul>
<dl class="todo"><dt><b><a class="el" href="todo.html#_todo000038">Todo:</a></b></dt><dd>Currently <code>Arena::Pointer</code> shall be a fancy-pointer, but we could support raw pointers also. Suppose <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8733c1237be93ee28664e4b983d535c" title="Short-hand for the Arena type this uses for allocation/deallocation/pointer semantics.">Arena_obj</a> is set up in such a way as to map all processes' locally-dereferenceable pointers to the same SHM location to the same numeric value (by specifying each pool's start as some predetermined numerical value in the huge 64-bit vaddr space &ndash; in all processes sharing that SHM pool. Now no address translation is needed, and <code>Arena::Pointer</code> could be simply <code>T*</code>. As of this writing some inner impl details suppose it being a fancy-pointer, and it's the only active need we have; but that could be tweaked with a bit of effort.</dd></dl>
<h3>Use in read-only borrowing mode</h3>
<p >Taken as an example, SHM-classic (<a class="el" href="classipc_1_1shm_1_1classic_1_1Pool__arena.html" title="A SHM-classic interface around a single SHM pool with allocation-algorithm services by boost....">shm::classic::Pool_arena</a>) <code>Arena</code>s can always both read and write, allocate and deallocate. By contrast, shm::arena_lend has allocate/write-capable <code>Arena</code> and, on the borrower side, read-only borrower-quasi-<code>Arena</code>. If one needs to merely <em>read</em> a SHM-stored STL-compliant structure with such an <code>Arena</code>, then <b>only the <code>Pointer</code> type requirement above applies</b>.</p><ul>
<li><code><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8609f6d096e59799d249403905a0953" title="Allocates an uninitialized buffer of given size, or throws exception if Arena_obj::allocate() does; s...">allocate()</a></code> and <code><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ac6531b5bdb3b299e0780fc5b892bd70c" title="Deallocates buffer in SHM previously allocated via allocate() in this or other (if Arena_obj supports...">deallocate()</a></code> shall not be used by (nor need to be present at compile-time for) <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html" title="Stateless allocator usable with STL-compliant containers to store (or merely read) them directly in S...">Stateless_allocator</a>.</li>
<li>No activator &ndash; in fact, no <code>Arena</code> <em>object</em> &ndash; only the <em>type</em>! &ndash; shall be used by <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html" title="Stateless allocator usable with STL-compliant containers to store (or merely read) them directly in S...">Stateless_allocator</a>.</li>
</ul>
<h3>Implementation</h3>
<p >It is self-explanatory; the trick was knowing what was actually required according to STL-compliance documentation. The great thing is, since C++11, only very few things are indeed needed in our situation; the rest is supplied with sensible default by <code>allocator_traits</code> which is how STL-compliant container code actually accesses <code><a class="el" href="classAllocator.html">Allocator</a></code>s like ours.</p>
<dl class="tparams"><dt>Template Parameters</dt><dd>
  <table class="tparams">
    <tr><td class="paramname">T</td><td>Pointed-to type for the allocator. See standard C++ <code><a class="el" href="classAllocator.html">Allocator</a></code> concept. </td></tr>
    <tr><td class="paramname">Arena</td><td>See above. </td></tr>
  </table>
  </dd>
</dl>

<p class="definition">Definition at line <a class="el" href="stateless__allocator_8hpp_source.html#l00118">118</a> of file <a class="el" href="stateless__allocator_8hpp_source.html">stateless_allocator.hpp</a>.</p>
</div><h2 class="groupheader">Member Typedef Documentation</h2>
<a id="ab8733c1237be93ee28664e4b983d535c" name="ab8733c1237be93ee28664e4b983d535c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab8733c1237be93ee28664e4b983d535c">&#9670;&nbsp;</a></span>Arena_obj</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T , typename Arena &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">using <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">ipc::shm::stl::Stateless_allocator</a>&lt; T, Arena &gt;::Arena_obj =  Arena</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Short-hand for the <code>Arena</code> type this uses for allocation/deallocation/pointer semantics. </p>

<p class="definition">Definition at line <a class="el" href="stateless__allocator_8hpp_source.html#l00127">127</a> of file <a class="el" href="stateless__allocator_8hpp_source.html">stateless_allocator.hpp</a>.</p>

</div>
</div>
<a id="ab2ed725ef3e8128a35f6ef429fb1fdcb" name="ab2ed725ef3e8128a35f6ef429fb1fdcb"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab2ed725ef3e8128a35f6ef429fb1fdcb">&#9670;&nbsp;</a></span>Pointer</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T , typename Arena &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">using <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">ipc::shm::stl::Stateless_allocator</a>&lt; T, Arena &gt;::Pointer =  typename Arena_obj::template <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab2ed725ef3e8128a35f6ef429fb1fdcb">Pointer</a>&lt;<a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#a8bf26ee2ae30dfbe4d64fbcad3ac8368">Value</a>&gt;</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>The required pointer-like type. See also <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ae1fc58777e7e727af17fbf0cdaf850bf" title="Alias to Pointer for compatibility with STL-compliant machinery (traits, etc.).">pointer</a>. </p>

<p class="definition">Definition at line <a class="el" href="stateless__allocator_8hpp_source.html#l00130">130</a> of file <a class="el" href="stateless__allocator_8hpp_source.html">stateless_allocator.hpp</a>.</p>

</div>
</div>
<a id="ae1fc58777e7e727af17fbf0cdaf850bf" name="ae1fc58777e7e727af17fbf0cdaf850bf"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae1fc58777e7e727af17fbf0cdaf850bf">&#9670;&nbsp;</a></span>pointer</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T , typename Arena &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">using <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">ipc::shm::stl::Stateless_allocator</a>&lt; T, Arena &gt;::pointer =  <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab2ed725ef3e8128a35f6ef429fb1fdcb">Pointer</a></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Alias to <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab2ed725ef3e8128a35f6ef429fb1fdcb" title="The required pointer-like type. See also pointer.">Pointer</a> for compatibility with STL-compliant machinery (traits, etc.). </p>

<p class="definition">Definition at line <a class="el" href="stateless__allocator_8hpp_source.html#l00133">133</a> of file <a class="el" href="stateless__allocator_8hpp_source.html">stateless_allocator.hpp</a>.</p>

</div>
</div>
<a id="a8bf26ee2ae30dfbe4d64fbcad3ac8368" name="a8bf26ee2ae30dfbe4d64fbcad3ac8368"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8bf26ee2ae30dfbe4d64fbcad3ac8368">&#9670;&nbsp;</a></span>Value</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T , typename Arena &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">using <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">ipc::shm::stl::Stateless_allocator</a>&lt; T, Arena &gt;::Value =  T</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Short-hand for <code>T</code>. </p>

<p class="definition">Definition at line <a class="el" href="stateless__allocator_8hpp_source.html#l00124">124</a> of file <a class="el" href="stateless__allocator_8hpp_source.html">stateless_allocator.hpp</a>.</p>

</div>
</div>
<a id="afa85349670ddd8da1eb0386a2556f753" name="afa85349670ddd8da1eb0386a2556f753"></a>
<h2 class="memtitle"><span class="permalink"><a href="#afa85349670ddd8da1eb0386a2556f753">&#9670;&nbsp;</a></span>value_type</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T , typename Arena &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">using <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">ipc::shm::stl::Stateless_allocator</a>&lt; T, Arena &gt;::value_type =  <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#a8bf26ee2ae30dfbe4d64fbcad3ac8368">Value</a></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Alias to <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#a8bf26ee2ae30dfbe4d64fbcad3ac8368" title="Short-hand for T.">Value</a> for compatibility with STL-compliant machinery (traits, etc.). </p>

<p class="definition">Definition at line <a class="el" href="stateless__allocator_8hpp_source.html#l00136">136</a> of file <a class="el" href="stateless__allocator_8hpp_source.html">stateless_allocator.hpp</a>.</p>

</div>
</div>
<h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a id="a07b30ebd16bf82a87186c7baffc9bf85" name="a07b30ebd16bf82a87186c7baffc9bf85"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a07b30ebd16bf82a87186c7baffc9bf85">&#9670;&nbsp;</a></span>Stateless_allocator() <span class="overload">[1/2]</span></h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T , typename Arena &gt; </div>
<div class="memtemplate">
template&lt;typename U &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">ipc::shm::stl::Stateless_allocator</a>&lt; T, Arena &gt;::Stateless_allocator </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">Stateless_allocator</a>&lt; U, Arena &gt; &amp;&#160;</td>
          <td class="paramname"><em>src_ignored</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">explicit</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p><a class="el" href="classAllocator.html">Allocator</a> concept requirement for copy-ctor from allocator-to-another-type: no-op since it's a stateless allocator. </p>
<dl class="tparams"><dt>Template Parameters</dt><dd>
  <table class="tparams">
    <tr><td class="paramname">U</td><td>Like <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#a8bf26ee2ae30dfbe4d64fbcad3ac8368" title="Short-hand for T.">Value</a>. </td></tr>
  </table>
  </dd>
</dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">src_ignored</td><td>The other allocator. </td></tr>
  </table>
  </dd>
</dl>

<p class="definition">Definition at line <a class="el" href="stateless__allocator_8hpp_source.html#l00238">238</a> of file <a class="el" href="stateless__allocator_8hpp_source.html">stateless_allocator.hpp</a>.</p>

</div>
</div>
<a id="aff55fe717e40aca873192819bf1afc15" name="aff55fe717e40aca873192819bf1afc15"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aff55fe717e40aca873192819bf1afc15">&#9670;&nbsp;</a></span>Stateless_allocator() <span class="overload">[2/2]</span></h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T , typename Arena &gt; </div>
<div class="memtemplate">
template&lt;typename U &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">ipc::shm::stl::Stateless_allocator</a>&lt; T, Arena &gt;::Stateless_allocator </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">Stateless_allocator</a>&lt; U, Arena &gt; &amp;&amp;&#160;</td>
          <td class="paramname"><em>src_ignored</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">explicit</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p><a class="el" href="classAllocator.html">Allocator</a> concept requirement for move-ctor from allocator-to-another-type: no-op since it's a stateless allocator. </p>
<dl class="tparams"><dt>Template Parameters</dt><dd>
  <table class="tparams">
    <tr><td class="paramname">U</td><td>Like <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#a8bf26ee2ae30dfbe4d64fbcad3ac8368" title="Short-hand for T.">Value</a>. </td></tr>
  </table>
  </dd>
</dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">src_ignored</td><td>The other allocator. </td></tr>
  </table>
  </dd>
</dl>

<p class="definition">Definition at line <a class="el" href="stateless__allocator_8hpp_source.html#l00245">245</a> of file <a class="el" href="stateless__allocator_8hpp_source.html">stateless_allocator.hpp</a>.</p>

</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a id="ab8609f6d096e59799d249403905a0953" name="ab8609f6d096e59799d249403905a0953"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab8609f6d096e59799d249403905a0953">&#9670;&nbsp;</a></span>allocate()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T , typename Arena &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">Stateless_allocator</a>&lt; T, Arena &gt;<a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab2ed725ef3e8128a35f6ef429fb1fdcb">::Pointer</a> <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">ipc::shm::stl::Stateless_allocator</a>&lt; T, Arena &gt;::allocate </td>
          <td>(</td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>n</em></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Allocates an uninitialized buffer of given size, or throws exception if <code>Arena_obj::allocate()</code> does; satisfies formal requirements of STL-compliant <code><a class="el" href="classAllocator.html">Allocator</a></code> concept. </p>
<p >See cppreference.com for those formal requirements.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">n</td><td>The buffer allocated shall be <code>n * sizeof(Value)</code>. Note: This is a <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#a8bf26ee2ae30dfbe4d64fbcad3ac8368" title="Short-hand for T.">Value</a> count; not a byte count. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Locally-dereferenceable pointer to the SHM-allocated buffer. The buffer is <em>not</em> initialized. E.g., depending on the nature of <code>T</code> you may want to placement-ct it at this address subsequently. </dd></dl>

<p class="definition">Definition at line <a class="el" href="stateless__allocator_8hpp_source.html#l00201">201</a> of file <a class="el" href="stateless__allocator_8hpp_source.html">stateless_allocator.hpp</a>.</p>

<p class="reference">References <a class="el" href="arena__activator_8hpp_source.html#l00107">ipc::shm::stl::Arena_activator&lt; Arena &gt;::this_thread_active_arena()</a>.</p>
<div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><iframe scrolling="no" frameborder="0" src="classipc_1_1shm_1_1stl_1_1Stateless__allocator_ab8609f6d096e59799d249403905a0953_cgraph.svg" width="352" height="59"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe>
</div>
</div>

</div>
</div>
<a id="ac6531b5bdb3b299e0780fc5b892bd70c" name="ac6531b5bdb3b299e0780fc5b892bd70c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac6531b5bdb3b299e0780fc5b892bd70c">&#9670;&nbsp;</a></span>deallocate()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T , typename Arena &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">ipc::shm::stl::Stateless_allocator</a>&lt; T, Arena &gt;::deallocate </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab2ed725ef3e8128a35f6ef429fb1fdcb">Pointer</a>&#160;</td>
          <td class="paramname"><em>p</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>n_ignored</em> = <code>0</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">noexcept</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Deallocates buffer in SHM previously allocated via <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8609f6d096e59799d249403905a0953" title="Allocates an uninitialized buffer of given size, or throws exception if Arena_obj::allocate() does; s...">allocate()</a> in this or other (if <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8733c1237be93ee28664e4b983d535c" title="Short-hand for the Arena type this uses for allocation/deallocation/pointer semantics.">Arena_obj</a> supports this) process, as long as <code>p</code> refers to the beginning of the buffer returned by that <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8609f6d096e59799d249403905a0953" title="Allocates an uninitialized buffer of given size, or throws exception if Arena_obj::allocate() does; s...">allocate()</a>; satisfies formal requirement of STL-compliant <code><a class="el" href="classAllocator.html">Allocator</a></code> concept. </p>
<p >See cppreference.com for those formal requirements. Does not throw (as required).</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">p</td><td>See above. </td></tr>
    <tr><td class="paramname">n_ignored</td><td>Ignored. </td></tr>
  </table>
  </dd>
</dl>

<p class="definition">Definition at line <a class="el" href="stateless__allocator_8hpp_source.html#l00218">218</a> of file <a class="el" href="stateless__allocator_8hpp_source.html">stateless_allocator.hpp</a>.</p>

<p class="reference">References <a class="el" href="arena__activator_8hpp_source.html#l00107">ipc::shm::stl::Arena_activator&lt; Arena &gt;::this_thread_active_arena()</a>.</p>
<div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><iframe scrolling="no" frameborder="0" src="classipc_1_1shm_1_1stl_1_1Stateless__allocator_ac6531b5bdb3b299e0780fc5b892bd70c_cgraph.svg" width="352" height="59"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe>
</div>
</div>

</div>
</div>
<h2 class="groupheader">Friends And Related Function Documentation</h2>
<a id="ab1b059d00a9cbdc54a917e051c1aecdf" name="ab1b059d00a9cbdc54a917e051c1aecdf"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab1b059d00a9cbdc54a917e051c1aecdf">&#9670;&nbsp;</a></span>operator!=()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Arena , typename T1 , typename T2 &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">bool operator!= </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">Stateless_allocator</a>&lt; T1, Arena &gt; &amp;&#160;</td>
          <td class="paramname"><em>val1</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">Stateless_allocator</a>&lt; T2, Arena &gt; &amp;&#160;</td>
          <td class="paramname"><em>val2</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">related</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Returns <code>false</code> for any 2 <code><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html" title="Stateless allocator usable with STL-compliant containers to store (or merely read) them directly in S...">Stateless_allocator</a></code>s managing the same <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8733c1237be93ee28664e4b983d535c" title="Short-hand for the Arena type this uses for allocation/deallocation/pointer semantics.">Stateless_allocator::Arena_obj</a>. </p>
<p >This satisfies formal requirements of STL-compliant <code><a class="el" href="classAllocator.html">Allocator</a></code> concept. See cppreference.com for those formal requirements. Since it's a stateless allocator, this always returns <code>false</code>.</p>
<dl class="tparams"><dt>Template Parameters</dt><dd>
  <table class="tparams">
    <tr><td class="paramname">Arena</td><td>See <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html" title="Stateless allocator usable with STL-compliant containers to store (or merely read) them directly in S...">Stateless_allocator</a>. </td></tr>
    <tr><td class="paramname">T1</td><td>See <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html" title="Stateless allocator usable with STL-compliant containers to store (or merely read) them directly in S...">Stateless_allocator</a>. </td></tr>
    <tr><td class="paramname">T2</td><td>See <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html" title="Stateless allocator usable with STL-compliant containers to store (or merely read) them directly in S...">Stateless_allocator</a>. </td></tr>
  </table>
  </dd>
</dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">val1</td><td>An allocator. </td></tr>
    <tr><td class="paramname">val2</td><td>An allocator. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>See above. </dd></dl>

<p class="definition">Definition at line <a class="el" href="stateless__allocator_8hpp_source.html#l00260">260</a> of file <a class="el" href="stateless__allocator_8hpp_source.html">stateless_allocator.hpp</a>.</p>

</div>
</div>
<a id="a96ccf3e4cf39d59d0a80e9026507b206" name="a96ccf3e4cf39d59d0a80e9026507b206"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a96ccf3e4cf39d59d0a80e9026507b206">&#9670;&nbsp;</a></span>operator==()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Arena , typename T1 , typename T2 &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">bool operator== </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">Stateless_allocator</a>&lt; T1, Arena &gt; &amp;&#160;</td>
          <td class="paramname"><em>val1</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html">Stateless_allocator</a>&lt; T2, Arena &gt; &amp;&#160;</td>
          <td class="paramname"><em>val2</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">related</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Returns <code>true</code> for any 2 <code><a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html" title="Stateless allocator usable with STL-compliant containers to store (or merely read) them directly in S...">Stateless_allocator</a></code>s managing the same <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html#ab8733c1237be93ee28664e4b983d535c" title="Short-hand for the Arena type this uses for allocation/deallocation/pointer semantics.">Stateless_allocator::Arena_obj</a>. </p>
<p >This satisfies formal requirements of STL-compliant <code><a class="el" href="classAllocator.html">Allocator</a></code> concept. See cppreference.com for those formal requirements. Since it's a stateless allocator, this always returns <code>true</code>.</p>
<dl class="tparams"><dt>Template Parameters</dt><dd>
  <table class="tparams">
    <tr><td class="paramname">Arena</td><td>See <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html" title="Stateless allocator usable with STL-compliant containers to store (or merely read) them directly in S...">Stateless_allocator</a>. </td></tr>
    <tr><td class="paramname">T1</td><td>See <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html" title="Stateless allocator usable with STL-compliant containers to store (or merely read) them directly in S...">Stateless_allocator</a>. </td></tr>
    <tr><td class="paramname">T2</td><td>See <a class="el" href="classipc_1_1shm_1_1stl_1_1Stateless__allocator.html" title="Stateless allocator usable with STL-compliant containers to store (or merely read) them directly in S...">Stateless_allocator</a>. </td></tr>
  </table>
  </dd>
</dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">val1</td><td>An allocator. </td></tr>
    <tr><td class="paramname">val2</td><td>An allocator. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>See above. </dd></dl>

<p class="definition">Definition at line <a class="el" href="stateless__allocator_8hpp_source.html#l00251">251</a> of file <a class="el" href="stateless__allocator_8hpp_source.html">stateless_allocator.hpp</a>.</p>

</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li>shm/stl/<a class="el" href="stateless__allocator_8hpp_source.html">stateless_allocator.hpp</a></li>
<li>shm/stl/<a class="el" href="stl__fwd_8hpp_source.html">stl_fwd.hpp</a></li>
</ul>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Fri Apr 11 2025 20:02:26 for Flow-IPC by&#160;<a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.4
</small></address>
</body>
</html>
